import request from '@/utils/aliyunRequest';

const expressApi = {};

expressApi.updateBasic = (params) => {
	return request({
		url: '/aliyun-api/express/update-basic',
		method: 'put',
		data: params,
	})
}
expressApi.placeOrder = (id) => {
	return request({
		url: '/aliyun-api/express/place-order/' + id,
		method: 'post',
	})
}
expressApi.downloadWills = (id) => {
	return request({
		url: '/aliyun-api/express/download-wills/' + id,
		method: 'get',
		responseType: 'arraybuffer',
	})
}
expressApi.routersSample = (sampleId) => {
	return request({
		url: '/aliyun-api/express/routers-sample/' + sampleId,
		method: 'get',
	})
}
expressApi.routers = (id) => {
	return request({
		url: '/aliyun-api/express/routers/' + id,
		method: 'get',
	})
}
expressApi.cancel = (sampleId) => {
	return request({
		url: '/aliyun-api/express/cancel/' + sampleId,
		method: 'put',
	})
}
expressApi.page = (params) => {
	return request({
		url: '/aliyun-api/express/page',
		method: 'get',
		params: params,
	})
}
expressApi.add = (params) => {
	return request({
		url: '/aliyun-api/express',
		method: 'post',
		data: params,
	})
}
expressApi.addFmtSample = (params) => {
	return request({
		url: '/aliyun-api/express/fmt-sample',
		method: 'post',
		data: params,
	})
}
expressApi.update = (params) => {
	return request({
		url: '/aliyun-api/express',
		method: 'put',
		data: params,
	})
}
expressApi.get = (id) => {
	return request({
		url: '/aliyun-api/express/' + id,
		method: 'get',
	})
}
expressApi.delete = (id) => {
	return request({
		url: '/aliyun-api/express/' + id,
		method: 'delete',
	})
}


export default expressApi